package _17作业.t3;

import java.util.HashSet;

public class Demo2 {
    public static void main(String[] args) {
        HashSet<Student> students =new HashSet<>();
        Student a = new Student("张三", "男", 21);
        Student b = new Student("李四", "男", 21);
        Student c = new Student("张三", "男", 20);
        Student d = new Student("张三", "女", 20);

        students.add(a);
        students.add(b);
        students.add(c);
        students.add(d);

        for (Student s : students){
            System.out.println(s);
        }

    }
}
